package com.zxy.demo.guava.eventbus;

import com.google.common.eventbus.Subscribe;

/**
 * EventListener1.
 * 
 * Created by zxybird on 17/3/18.
 */
public class EventListener1 {

  public int lastMessage = 0;

  @Subscribe
  public void listen(TestEvent1 event) {
    lastMessage = event.getMessage();
    System.out.println("Message1:" + lastMessage);
    throw new RuntimeException("haha");
  }

  public int getLastMessage() {
    return lastMessage;
  }

}
